package com.zone.lib.download.bean;


import com.zone.lib.download.db.entity.Download;
import com.zone.sdk.module.appstore.entity.AppEntity;

import java.io.File;
import java.io.Serializable;

public class DownloadInfo implements Serializable{

    private static final long serialVersionUID = -4822775624947410734L;

    private String code;
    private String appUrl;
    private File file;
    private int action; // 广播接受者的各种行为
    private String userId;
    private String vin;
    private String type;
    private String clientName;
    private String downloadUrl;
    private long size;
    private String version;

    private AppEntity appEntity;
    private Download download;

    public DownloadInfo(){}

    public DownloadInfo(String code, String appUrl, File file, int action, String downloadUrl, long size, String version) {
        this.code = code;
        this.appUrl = appUrl;
        this.file = file;
        this.action = action;
        this.downloadUrl = downloadUrl;
        this.size = size;
        this.version = version;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getAppUrl() {
        return appUrl;
    }

    public void setAppUrl(String appUrl) {
        this.appUrl = appUrl;
    }

    public File getFile() {
        return file;
    }

    public void setFile(File file) {
        this.file = file;
    }

    public int getAction() {
        return action;
    }

    public void setAction(int action) {
        this.action = action;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getVin() {
        return vin;
    }

    public void setVin(String vin) {
        this.vin = vin;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getClientName() {
        return clientName;
    }

    public void setClientName(String clientName) {
        this.clientName = clientName;
    }

    public String getDownloadUrl() {
        return downloadUrl;
    }

    public void setDownloadUrl(String downloadUrl) {
        this.downloadUrl = downloadUrl;
    }

    public long getSize() {
        return size;
    }

    public void setSize(long size) {
        this.size = size;
    }

    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public AppEntity getAppEntity() {
        return appEntity;
    }

    public void setAppEntity(AppEntity appEntity) {
        this.appEntity = appEntity;
    }

    public Download getDownload() {
        return download;
    }

    public void setDownload(Download download) {
        this.download = download;
    }

    @Override
    public String toString() {
        return "DownloadInfo{" +
                "code='" + code + '\'' +
                ", appUrl='" + appUrl + '\'' +
                ", file=" + file +
                ", action='" + action + '\'' +
                ", userId='" + userId + '\'' +
                ", vin='" + vin + '\'' +
                ", type='" + type + '\'' +
                ", clientName='" + clientName + '\'' +
                ", downloadUrl='" + downloadUrl + '\'' +
                '}';
    }
}
